<?php
use think\facade\Route;

Route::resource('organization', 'organization.Index')->only(['index', 'save', 'update', 'delete']);

//组织管理路由
Route::group('/organization', function () {
    Route::get('/get_teams', 'Organization.Index/get_teams');
    Route::post('/join_team', 'Organization.Index/team_join');
    Route::get('/grade_capacity', 'Organization.Index/grade_capacity');
});
//角色管理路由
Route::resource('/organization/role', 'organization.Role')
    ->only(['index', 'save', 'update', 'delete'])
    ->pattern(['id' => '\d+']);

Route::resource('/organization/member', 'organization.Member')
    ->only(['index', 'update', 'delete'])
    ->pattern(['id' => '\d+']);

//通过手机号码查询用户信息，邀请用户加入组织
Route::get('/user/get_user_by_mobile', 'User/get_user_by_mobile');